import pandas as pd
from sqlalchemy import create_engine

#engine = create_engine("mysql+pymysql://fecy:Jili@123@172.23.135.5:3306/scrapy")
engine = create_engine("mysql+pymysql://cl007:ChengLei-0711@127.0.0.1:3306/scrapy?charset=utf8")
sql = 'select * from scrapy.baidu_general_brand'
data = pd.read_sql(sql,engine)
data = data.set_index('date')
print(data)